Skip to main content

Create Association

AutomatR.HubSpot.Activities.CreateAssociation

The "Create Association" activity in AutomatR for HubSpot allows you to create associations between different objects in your HubSpot user account, such as associating a contact with a company. This activity is part of the HubSpot activities package and simplifies the process of managing associations in HubSpot.

Properties

NameDescription
Input
From Object IDEnter the ID of the object from which the association originates. For example, the Contact ID when associating with a company. String variables containing the from object ID.
To Object IDEnter the ID of the object to which the association is made. For example, the Company ID when associating with a contact. String variables containing the to object ID.
TypeEnter the type of association. For example, "contact_to_company." String variables containing the association type.
From Object TypeEnter the type of the object from which the association originates. For example, "contacts." String variables containing the from object type.
To Object TypeEnter the type of the object to which the association is made. For example, "companies." String variables containing the to object type.
Misc
Display NameProvides a customizable name for the activity displayed in the workflow. The display name enhances clarity and organization within the automation project. String variables containing the desired display name.
Optional
DelayEnter the wait time in seconds (e.g., 5 seconds) to start the activity. Integer variables containing the delay duration.
Output
ResultReturns true or false based on the success of the association. Boolean variables to store the operation result.

How to Use

  1. Drag and drop the "Create Association" activity onto the workflow.
  2. Configure the properties by specifying the from object ID, to object ID, association type, from object type, and to object type.
  3. Optionally, configure the delay and customize the display name.
  4. Execute the workflow to create the association between the specified objects in HubSpot.

Example:

Consider an example where the "Create Association" activity is used to associate a contact with a company in HubSpot:

Create Association:
Display Name: "Associate Contact with Company"
From Object ID: "123" (Contact ID)
To Object ID: "456" (Company ID)
Type: "contact_to_company"
From Object Type: "contacts"
To Object Type: "companies"
Result: isAssociationSuccessful

In this example, the activity creates an association between a contact with ID "123" and a company with ID "456." The association type is "contact_to_company," and the result of the operation (success or failure) is stored in the Boolean variable "isAssociationSuccessful" for further handling in the workflow.